package com.sql;

import java.sql.Connection;

import java.sql.DriverManager;

import oracle.jdbc.OracleDriver;

public class SqlManagers {
    public SqlManagers() {
        super();
    }
    
    public Connection getCon() {
        Connection con = null;
        
        try {
            // Tao 1 ket noi toi database oracle
            Class.forName("oracle.jdbc.OracleDriver");
            con = DriverManager.getConnection("jdbc:oracle:thin:@192.168.100.50:1521:ORACTRDB", "oractr", "oractr");
        }
        catch(Exception ex) {
            ex.printStackTrace();
        }
        return con;
    }
}
